home *** CD-ROM | disk | FTP | other *** search
- #ifndef __MAINFUNC__
- #include "MainFunctions.h"
- #endif
-
- extern SpeechChannel theSpeechChan;
- extern Boolean gDone;
- extern Byte formingByte;
- extern Boolean inputBufferHalfByte;
-
- OSErr ParseRefCon (SpeechInfoPtr theSpeechInfo, CommandPtr theCommand)
- {
- long type = 0;
- OSErr theErr = noErr;
- short hexdig = 0;
- Boolean done = false,
- found = false;
-
- #pragma unused (theSpeechInfo)
-
- hexdig = theCommand->ID;
-
- if (inputBufferHalfByte) {
- formingByte |= (Byte)hexdig;
- inputBufferHalfByte = false;
- // now post it to the frontmost application
- PostEvent(keyDown, formingByte);
-
-
- } else {
- formingByte = (Byte)hexdig << 4;
- inputBufferHalfByte = true;
- }
-
- return theErr;
- }
-